<?php

namespace App\Http\Controllers\Admin;

use App\Http\Controllers\Controller;
use Illuminate\Http\Request;
use App\Models\Admin\Good;

class GoodController extends Controller
{

    public function getList(Request $request)
    {
        $good = new Good;
        $data = $good->getList($request);

        return $data;
    }

    public function handleInit(Request $request)
    {
        $good = new Good;
        $data = $good->handleInit($request);

        return $data;
    }

    public function handle(Request $request)
    {
        $good = new Good;
        $result = $good->handle($request);

        return $result;
    }

    public function loadData(Request $request)
    {
        $id = $request['id'];

        $good = new Good;
        $data = $good->loadData($id);

        return $data;
    }

    public function delete(Request $request)
    {
        $id = $request['id'];

        $good = new Good;
        $data = $good->deleteAction($id);

        return $data;
    }
}
